<html>
<head><meta charset="utf-8"><title>Unoptimised compiler builds · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Unoptimised.20compiler.20builds.html">Unoptimised compiler builds</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="205343246"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/Unoptimised%20compiler%20builds/near/205343246" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Edd Barrett <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/Unoptimised.20compiler.20builds.html#205343246">(Jul 29 2020 at 11:18)</a>:</h4>
<p>Hi,</p>
<p>I have a (pretty niche) need for a build of the standard library without optimisations enabled.</p>
<p>In <code>config.toml.example</code> there's <a href="https://github.com/rust-lang/rust/blob/10c375700ce170fc57cb617754dc6d0631d3d573/config.toml.example#L282">a comment warning against these kind of shenanighans</a>:</p>
<div class="codehilite"><pre><span></span><code># Whether or not to optimize the compiler and standard library.
# WARNING: Building with optimize = false is NOT SUPPORTED. Due to bootstrapping,
# building without optimizations takes much longer than optimizing. Further, some platforms
# fail to build without this optimization (c.f. #65352).
#optimize = true
</code></pre></div>


<p>The <a href="https://github.com/rust-lang/rust/issues/65352">cited issue</a> is a windows bug closed last year, so this comment may be stale.</p>
<p>FWIW, if you turn optimisation off today, then many tests fail with weird linkage errors etc. Here's <a href="https://gist.github.com/vext01/720205a993043b1824dbae19799c082a">the full output of a test run without optimisation</a>.</p>
<p>So I'm wondering: should debug builds work? And is there any interest in having them work?</p>
<p>Many Thanks!</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>